package router

import (
	cedar_session "github.com/tungyao/cedar-session"
	"net/http"
	"time"
)

// 这个方法是用来生成 用户唯一UUId

func CreateUUID(w http.ResponseWriter, r *http.Request, s cedar_session.Session) {
	d, err := ToJSon(&uuidJSON{}, createUUID(r.RemoteAddr), time.Now().Unix())
	if IsError(err, w) {
		w.Write(d)
	}
}
